package com.homedo.odin.solution.model.request.mng.column;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.List;
import javax.validation.Valid;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import lombok.Data;
import org.hibernate.validator.constraints.NotEmpty;
import org.hibernate.validator.constraints.Range;

@ApiModel(description = "新增修改栏目信息")
@JsonIgnoreProperties(ignoreUnknown = true)
@Data
public class SpecialColumnRequestBean {

    @ApiModelProperty("栏目Id")
    private Long columnId;

    @ApiModelProperty("作者id")
    @NotNull(message = "expertId不能为空")
    @Min(message = "expertId非法", value = 0)
    private Integer expertId;

    @ApiModelProperty("作者名称")
    @NotEmpty(message = "作者名称非法")
    private String expertName;

    @ApiModelProperty("栏目标题")
    @NotEmpty(message = "栏目标题不能为空")
    private String columnTitle;

    @ApiModelProperty("栏目导读")
    @NotEmpty(message = "栏目导读不能为空")
    private String columnIntroduction;

    @ApiModelProperty("栏目配图")
    private String matchPic;

    @ApiModelProperty("栏目类型 1.专栏栏目2.视频栏目")
    @NotNull(message = "栏目类型不能为空")
    @Range(min = 1, max = 2, message = "栏目类型（1.专栏栏目2.视频栏目）")
    private Integer columnType;

    @ApiModelProperty("标签id")
    @NotNull(message = "标签id不能为空")
    @Min(message = "标签id不能为空", value = 0)
    private Integer tagId;

    @ApiModelProperty("栏目文本内容")
    private String columnText;

    @ApiModelProperty("视频首帧地址")
    private String videoPic;
    @Valid
    @ApiModelProperty("视频介绍")
    private String videoIntroduction;

    @ApiModelProperty("栏目视频存储位置")
    private String columnVideo;

    @ApiModelProperty("栏目资源列表")
    @Valid
    private List<ColumnResourceRequestBean> resourceList;

    @ApiModelProperty("编辑人id")
    private String editorId;

    @ApiModelProperty("编辑人名称")
    private String editorName;


}
